home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 2 / AACD 2.iso / AACD / Magazine / GraphicsCards / StormMesa / src / config.h < prev    next >
C/C++ Source or Header  |  1999-02-04  |  4KB  |  223 lines

  1. /* $Id: config.h,v 3.4 1998/06/22 03:16:15 brianp Exp $ */
  2.  
  3. /*
  4.  * Mesa 3-D graphics library
  5.  * Version:  3.0
  6.  * Copyright (C) 1995-1998  Brian Paul
  7.  *
  8.  * This library is free software; you can redistribute it and/or
  9.  * modify it under the terms of the GNU Library General Public
  10.  * License as published by the Free Software Foundation; either
  11.  * version 2 of the License, or (at your option) any later version.
  12.  *
  13.  * This library is distributed in the hope that it will be useful,
  14.  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  15.  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  16.  * Library General Public License for more details.
  17.  *
  18.  * You should have received a copy of the GNU Library General Public
  19.  * License along with this library; if not, write to the Free
  20.  * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  21.  */
  22.  
  23.  
  24. /*
  25.  * $Log: config.h,v $
  26.  * Revision 3.4  1998/06/22 03:16:15  brianp
  27.  * added VB_MAX define and MITS test
  28.  *
  29.  * Revision 3.3  1998/06/07 22:18:52  brianp
  30.  * implemented GL_EXT_multitexture extension
  31.  *
  32.  * Revision 3.2  1998/06/02 23:51:04  brianp
  33.  * added CHAN_BITS and GLchan type (for the future)
  34.  *
  35.  * Revision 3.1  1998/02/20 04:53:37  brianp
  36.  * implemented GL_SGIS_multitexture
  37.  *
  38.  * Revision 3.0  1998/01/31 20:48:53  brianp
  39.  * initial rev
  40.  *
  41.  */
  42.  
  43.  
  44.  
  45. /*
  46.  * Tunable configuration parameters.
  47.  */
  48.  
  49.  
  50.  
  51. #ifndef CONFIG_H
  52. #define CONFIG_H
  53.  
  54.  
  55. /*
  56.  *
  57.  * OpenGL implementation limits
  58.  *
  59.  */
  60.  
  61.  
  62. /* Maximum modelview matrix stack depth: */
  63. #define MAX_MODELVIEW_STACK_DEPTH 32
  64.  
  65. /* Maximum projection matrix stack depth: */
  66. #define MAX_PROJECTION_STACK_DEPTH 32
  67.  
  68. /* Maximum texture matrix stack depth: */
  69. #define MAX_TEXTURE_STACK_DEPTH 10
  70.  
  71. /* Maximum attribute stack depth: */
  72. #define MAX_ATTRIB_STACK_DEPTH 16
  73.  
  74. /* Maximum client attribute stack depth: */
  75. #define MAX_CLIENT_ATTRIB_STACK_DEPTH 16
  76.  
  77. /* Maximum recursion depth of display list calls: */
  78. #define MAX_LIST_NESTING 64
  79.  
  80. /* Maximum number of lights: */
  81. #define MAX_LIGHTS 8
  82.  
  83. /* Maximum user-defined clipping planes: */
  84. #define MAX_CLIP_PLANES 6
  85.  
  86. /* Number of texture levels */
  87. #ifdef FX
  88. #define MAX_TEXTURE_LEVELS 9
  89. #else
  90. #define MAX_TEXTURE_LEVELS 11
  91. #endif
  92.  
  93. /* Max texture size */
  94. #define MAX_TEXTURE_SIZE   (1 << (MAX_TEXTURE_LEVELS-1))
  95.  
  96. /* Maximum pixel map lookup table size: */
  97. #define MAX_PIXEL_MAP_TABLE 256
  98.  
  99. /* Number of auxillary color buffers: */
  100. #define NUM_AUX_BUFFERS 0
  101.  
  102. /* Maximum order (degree) of curves: */
  103. #ifdef AMIGA
  104. #   define MAX_EVAL_ORDER 12
  105. #else
  106. #   define MAX_EVAL_ORDER 30
  107. #endif
  108.  
  109. /* Maximum Name stack depth */
  110. #define MAX_NAME_STACK_DEPTH 64
  111.  
  112. /* Min and Max point sizes and granularity */
  113. #define MIN_POINT_SIZE 1.0
  114. #define MAX_POINT_SIZE 10.0
  115. #define POINT_SIZE_GRANULARITY 0.1
  116.  
  117. /* Min and Max line widths and granularity */
  118. #define MIN_LINE_WIDTH 1.0
  119. #define MAX_LINE_WIDTH 10.0
  120. #define LINE_WIDTH_GRANULARITY 1.0
  121.  
  122. /* Max texture palette size */
  123. #define MAX_TEXTURE_PALETTE_SIZE 256
  124.  
  125. /* Number of texture maps and environments - GL_EXT_multitexture */
  126. #define MAX_TEX_SETS 2
  127.  
  128. /* Number of texture coordinate sets - GL_EXT_multitexture */
  129. #define MAX_TEX_COORD_SETS 2
  130.  
  131.  
  132. #define MAX_WIDTH 1600
  133. #define MAX_HEIGHT 1200
  134.  
  135.  
  136.  
  137.  
  138. /*
  139.  *
  140.  * Mesa-specific parameters
  141.  *
  142.  */
  143.  
  144.  
  145. /*
  146.  * Bits per color channel (must be 8 at this time!)
  147.  */
  148. #define CHAN_BITS 8
  149.  
  150.  
  151. /*
  152.  * Bits per accumulation buffer color component:  8 or 16
  153.  */
  154. #define ACCUM_BITS 16
  155.  
  156.  
  157. /*
  158.  * Bits per depth buffer value:  16 or 32
  159.  */
  160. #define DEPTH_BITS 16
  161.  
  162. #if DEPTH_BITS==16
  163. #  define MAX_DEPTH 0xffff
  164. #  define DEPTH_SCALE 65535.0F
  165. #elif DEPTH_BITS==32
  166. #  define MAX_DEPTH 0x00ffffff
  167. #  define DEPTH_SCALE ((GLfloat) 0x00ffffff)
  168. #else
  169.    invalid value!
  170. #endif
  171.  
  172.  
  173. /*
  174.  * Bits per stencil value:  8
  175.  */
  176. #define STENCIL_BITS 8
  177.  
  178.  
  179.  
  180. /*
  181.  * Color channel component order
  182.  * (changes will almost certainly cause problems at this time)
  183.  */
  184. #define RCOMP 0
  185. #define GCOMP 1
  186. #define BCOMP 2
  187. #define ACOMP 3
  188.  
  189.  
  190.  
  191. /*
  192.  * Vertex buffer size.  Must be a multiple of 12.
  193.  */
  194. #ifdef AMIGA
  195. #define VB_MAX 84
  196. #else
  197.  
  198. #if (defined(FX) && !defined(MITS))
  199. #  define VB_MAX 72   /* better performance */
  200. #else
  201. #  define VB_MAX 480
  202. #endif
  203.  
  204. #endif
  205.  
  206.  
  207.  
  208. /*
  209.  *
  210.  * For X11 driver only:
  211.  *
  212.  */
  213.  
  214. /*
  215.  * When defined, use 6x6x6 dithering instead of 5x9x5.
  216.  * 5x9x5 better for general colors, 6x6x6 better for grayscale.
  217.  */
  218. /*#define DITHER666*/
  219.  
  220.  
  221.  
  222. #endif
  223.